home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / fld2_16 / ejfold2.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1994-12-28  |  8.9 KB  |  288 lines

  1. VERSION 2.00
  2. Begin Form Form2 
  3.    BackColor       =   &H00808080&
  4.    BorderStyle     =   3  'Fixed Double
  5.    Caption         =   "Test Folder"
  6.    ClientHeight    =   4356
  7.    ClientLeft      =   1596
  8.    ClientTop       =   1920
  9.    ClientWidth     =   7656
  10.    ControlBox      =   0   'False
  11.    Height          =   4800
  12.    Left            =   1536
  13.    LinkTopic       =   "Form2"
  14.    MaxButton       =   0   'False
  15.    MinButton       =   0   'False
  16.    ScaleHeight     =   4356
  17.    ScaleWidth      =   7656
  18.    Top             =   1536
  19.    Width           =   7776
  20.    Begin CommandButton Command1 
  21.       Caption         =   "Between Tabs"
  22.       Height          =   372
  23.       Index           =   4
  24.       Left            =   5400
  25.       TabIndex        =   16
  26.       Top             =   3492
  27.       Width           =   1416
  28.    End
  29.    Begin CommandButton Command2 
  30.       Caption         =   "First Form"
  31.       Height          =   336
  32.       Left            =   3024
  33.       TabIndex        =   15
  34.       Top             =   3960
  35.       Width           =   1308
  36.    End
  37.    Begin CommandButton Command1 
  38.       Caption         =   "Side"
  39.       Height          =   372
  40.       Index           =   3
  41.       Left            =   4428
  42.       TabIndex        =   10
  43.       Top             =   3492
  44.       Width           =   912
  45.    End
  46.    Begin CommandButton Command1 
  47.       Caption         =   "Tabs per Row"
  48.       Height          =   372
  49.       Index           =   2
  50.       Left            =   2880
  51.       TabIndex        =   9
  52.       Top             =   3492
  53.       Width           =   1488
  54.    End
  55.    Begin CommandButton Command1 
  56.       Caption         =   "RowOffset"
  57.       Height          =   372
  58.       Index           =   1
  59.       Left            =   1584
  60.       TabIndex        =   8
  61.       Top             =   3492
  62.       Width           =   1236
  63.    End
  64.    Begin CommandButton Command1 
  65.       Caption         =   "Style"
  66.       Height          =   372
  67.       Index           =   0
  68.       Left            =   612
  69.       TabIndex        =   7
  70.       Top             =   3492
  71.       Width           =   912
  72.    End
  73.    Begin PictureBox Picture1 
  74.       Height          =   264
  75.       Index           =   0
  76.       Left            =   36
  77.       ScaleHeight     =   240
  78.       ScaleWidth      =   240
  79.       TabIndex        =   6
  80.       TabStop         =   0   'False
  81.       Top             =   2448
  82.       Width           =   264
  83.    End
  84.    Begin PictureBox Picture1 
  85.       Height          =   264
  86.       Index           =   1
  87.       Left            =   36
  88.       ScaleHeight     =   240
  89.       ScaleWidth      =   240
  90.       TabIndex        =   5
  91.       TabStop         =   0   'False
  92.       Top             =   2160
  93.       Width           =   264
  94.    End
  95.    Begin SSPanel folder 
  96.       Alignment       =   0  'Left Justify - TOP
  97.       BevelWidth      =   2
  98.       BorderWidth     =   1
  99.       Caption         =   "Test Folder, Tab 4"
  100.       FloodColor      =   &H00000000&
  101.       ForeColor       =   &H00FFFFFF&
  102.       Height          =   1452
  103.       Index           =   4
  104.       Left            =   6624
  105.       Outline         =   -1  'True
  106.       TabIndex        =   4
  107.       Tag             =   "Tabs1"
  108.       Top             =   2304
  109.       Width           =   2172
  110.    End
  111.    Begin SSPanel folder 
  112.       Alignment       =   0  'Left Justify - TOP
  113.       BevelWidth      =   2
  114.       BorderWidth     =   1
  115.       Caption         =   "Test Folder, Tab 3"
  116.       ForeColor       =   &H00FFFFFF&
  117.       Height          =   1452
  118.       Index           =   3
  119.       Left            =   6480
  120.       Outline         =   -1  'True
  121.       TabIndex        =   3
  122.       Tag             =   "Tabs1"
  123.       Top             =   2160
  124.       Width           =   2172
  125.    End
  126.    Begin SSPanel folder 
  127.       Alignment       =   0  'Left Justify - TOP
  128.       BevelWidth      =   2
  129.       BorderWidth     =   1
  130.       Caption         =   "Test Folder, Tab 2"
  131.       FloodColor      =   &H0000FF00&
  132.       Height          =   1452
  133.       Index           =   2
  134.       Left            =   6336
  135.       Outline         =   -1  'True
  136.       TabIndex        =   2
  137.       Tag             =   "Tabs1"
  138.       Top             =   2016
  139.       Width           =   2172
  140.    End
  141.    Begin SSPanel folder 
  142.       Alignment       =   0  'Left Justify - TOP
  143.       BevelWidth      =   2
  144.       BorderWidth     =   1
  145.       Caption         =   "Test Folder, Tab 1"
  146.       FloodColor      =   &H0000FFFF&
  147.       Height          =   1452
  148.       Index           =   1
  149.       Left            =   6192
  150.       Outline         =   -1  'True
  151.       TabIndex        =   0
  152.       Tag             =   "Tabs1"
  153.       Top             =   1836
  154.       Width           =   2172
  155.    End
  156.    Begin SSPanel folder 
  157.       Alignment       =   0  'Left Justify - TOP
  158.       BevelWidth      =   2
  159.       BorderWidth     =   1
  160.       Caption         =   "Test Folder, Tab 0"
  161.       FloodColor      =   &H000000FF&
  162.       Height          =   1992
  163.       Index           =   0
  164.       Left            =   900
  165.       Outline         =   -1  'True
  166.       TabIndex        =   1
  167.       Tag             =   "Tabs1"
  168.       Top             =   108
  169.       Width           =   5808
  170.       Begin SSPanel texto 
  171.          BevelInner      =   1  'Inset
  172.          BorderWidth     =   0
  173.          Caption         =   "Between"
  174.          Height          =   264
  175.          Index           =   4
  176.          Left            =   324
  177.          RoundedCorners  =   0   'False
  178.          TabIndex        =   17
  179.          Top             =   1620
  180.          Width           =   5088
  181.       End
  182.       Begin SSPanel texto 
  183.          BevelInner      =   1  'Inset
  184.          BorderWidth     =   0
  185.          Caption         =   "Side"
  186.          Height          =   264
  187.          Index           =   3
  188.          Left            =   324
  189.          RoundedCorners  =   0   'False
  190.          TabIndex        =   11
  191.          Top             =   1296
  192.          Width           =   5088
  193.       End
  194.       Begin SSPanel texto 
  195.          BevelInner      =   1  'Inset
  196.          BorderWidth     =   0
  197.          Caption         =   "Tabs/Row"
  198.          Height          =   264
  199.          Index           =   2
  200.          Left            =   324
  201.          RoundedCorners  =   0   'False
  202.          TabIndex        =   14
  203.          Top             =   972
  204.          Width           =   5088
  205.       End
  206.       Begin SSPanel texto 
  207.          BevelInner      =   1  'Inset
  208.          BorderWidth     =   0
  209.          Caption         =   "RowOffset"
  210.          Height          =   264
  211.          Index           =   1
  212.          Left            =   324
  213.          RoundedCorners  =   0   'False
  214.          TabIndex        =   13
  215.          Top             =   648
  216.          Width           =   5088
  217.       End
  218.       Begin SSPanel texto 
  219.          BevelInner      =   1  'Inset
  220.          BorderWidth     =   0
  221.          Caption         =   "Style"
  222.          Height          =   264
  223.          Index           =   0
  224.          Left            =   324
  225.          RoundedCorners  =   0   'False
  226.          TabIndex        =   12
  227.          Top             =   324
  228.          Width           =   5088
  229.       End
  230.    End
  231. Option Explicit
  232. Dim estilo As Integer
  233. Dim rowofs As Integer
  234. Dim tabsperrow As Integer
  235. Dim lado As Integer
  236. Dim betw As Integer
  237. Sub adjust_text ()
  238.     Dim s As String
  239.     Select Case estilo
  240.         Case 0: s$ = "Normal/Chamfered"
  241.         Case 1: s$ = "Slanted"
  242.         Case 2: s$ = "Chicago"
  243.     End Select
  244.     texto(0).Caption = "Style: " & s$
  245.     texto(1).Caption = "Row Offset: " & rowofs
  246.     texto(2).Caption = "Tabs per Row: " & tabsperrow
  247.     Select Case lado
  248.         Case False: s$ = "Right"
  249.         Case True: s$ = "Left"
  250.     End Select
  251.     texto(3).Caption = "Side: " & s$
  252.     texto(4).Caption = "Between: " & (betw - 12)
  253. End Sub
  254. Sub Command1_Click (Index As Integer)
  255.     Dim success As Integer
  256.     Select Case Index
  257.         Case 0: estilo = (estilo + 1) Mod 3
  258.         Case 1: rowofs = (rowofs + 6) Mod 18
  259.         Case 2: tabsperrow = 1 + tabsperrow Mod 5
  260.         Case 3: lado = Not lado
  261.         Case 4: betw = (betw + 12) Mod 36
  262.     End Select
  263.     success = ReDefineFolders(2, tabsperrow, estilo, rowofs, 0, True, lado, betw - 12)
  264.     adjust_text
  265. End Sub
  266. Sub Command2_Click ()
  267.     Hide
  268. End Sub
  269. Sub Form_Load ()
  270.     Dim success As Integer
  271.     Move (screen.Width - Width) \ 2, (screen.Height - Height) \ 2
  272.     estilo = 0
  273.     rowofs = 0
  274.     tabsperrow = 1
  275.     lado = False
  276.     betw = 12
  277.     success = DefineFolders(2, tabsperrow, folder(0), "Tabs1", picture1(0), picture1(1), Nothing, estilo, rowofs, 0, True, lado, betw - 12)
  278.     SetFixedControl 2, texto(0)
  279.     SetFixedControl 2, texto(1)
  280.     SetFixedControl 2, texto(2)
  281.     SetFixedControl 2, texto(3)
  282.     SetFixedControl 2, texto(4)
  283.     adjust_text
  284. End Sub
  285. Sub Picture1_MouseUp (Index As Integer, Button As Integer, Shift As Integer, X As Single, Y As Single)
  286.     If Index = 0 Then FolderClick 2, Button, X, Y
  287. End Sub
  288.